import request from '../../request.js'


/**
 * 查询对应标签的商品信息
 * 
 */
function getCommById(data) {
	return request({
		url: '/api/wx/comm/list/commId',
		method: 'GET',
		data: data,
		header: {
			Authorization: uni.getStorageSync('token'),
			'Content-Type': 'application/x-www-form-urlencoded'
		},
	})
}

/**
 * 将对应商品加入购物车
 * 
 */
function commSetCar(data) {
	return request({
		url: '/fuw/car',
		method: 'POST',
		data: data,
		header: {
			Authorization: uni.getStorageSync('token'),
		},
	})
}

//一定要声明暴露函数，可以被引用 
module.exports = {
	getCommById,
	commSetCar
}